babl-fish: fix concurrent babl_fish()/process() calls with palette formats
authorEll <ell_se@yahoo.com>
Thu, 14 Jun 2018 05:54:52 +0000 (01:54 -0400)
committerEll <ell_se@yahoo.com>
Thu, 14 Jun 2018 06:22:44 +0000 (02:22 -0400)
commit4701c2dcb18e264b93536438798a6063832c0838
tree357617fec26581c09ffc384e50bfb67fca75889c
parente2ace5f161d65a00282c09cf2a13fc182bffc139
babl-fish: fix concurrent babl_fish()/process() calls with palette formats

In babl_fish(), don't call _babl_fish_rig_dispatch() on existing
path fishes during each lookup.  We already call this function on
all path fishes upon creation (in particular, after commit
b34a9672c8c9a42923a8f0b2650af30b1efe635c), so this isn't necessary.

This fixes an issue where the _babl_fish_rig_dispatch() call in
babl_fish() would temporarily modify the value of babl->fish.data,
causing a concurrent babl_process[_rows]() call in another thread
to pass the wrong 'data' value down to the conversion function.  In
particular, this could cause palette conversions to segfault.
babl/babl-fish.c